/**
 * 关键词 Api
 * @type {SysKeywordRepoApi}
 */
const sysKeywordRepoApi = new class SysKeywordRepoApi extends BaseApi {
    constructor() {
        super({
            url: '/api/sysKeywordRepo',
            exp: true,
            imp: true,
        })
    }

    async updateStatusById(id){
        return (await rxajax.get(super.using(`/update_status/${id}`))).data.data
    }
    async updateCategoryById(id,category){
        return (await rxajax.get(super.using(`/update_category/${id}/${category}`))).data.data
    }

    async deleteById(id){
        return (await rxajax.get(super.using(`/delete/${id}`))).data.data
    }
    async downloadTemplate(){
        return (await rxajax.get(super.using(`/getExcelTemplate1`))).data
    }

    async updateOrAdd(data) {
        return (await rxajax.post(super.using(`/update-or-add`), data, {type: 'json'})).data
    }
}